package com.ntd.pushpush.api;

import android.content.Context;

// TODO
public class RequestProgressConfig {
    private Context context;
    private String message;
    private boolean cancelable;

    private RequestProgressConfig(Context context, String  message, boolean cancelable) {
        this.context = context;
        this.message = message;
        this.cancelable = cancelable;
    }

    public static RequestProgressConfig requestWaiting(Context context) {
        return requestWaiting(context,  "正在发送请求，请稍候", true);
    }

    public static RequestProgressConfig requestWaiting(Context context, boolean cancelable) {
        return new RequestProgressConfig(context, "正在发送请求，请稍候", cancelable);
    }

    public static RequestProgressConfig requestWaiting(Context context, String message) {
        return requestWaiting(context, message, true);
    }

    public static RequestProgressConfig requestWaiting(Context context, String message,
                                                       boolean cancelable) {
        return new RequestProgressConfig(context, message, cancelable);
    }

    public Context getContext() {
        return context;
    }

    public String getMessage() {
        return message;
    }

    public boolean getCancelable() {
        return cancelable;
    }
}
